<%@ page contentType="text/html;charset=UTF-8" language="java"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="/jstl/fn" prefix="fn"%>
<!DOCTYPE html>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport"
	content="width=device-width,initial-scale=1 user-scalable=0">
<link rel="stylesheet" href="<%=basePath%>/assets/css/public.css">
<title>个人中心</title>
<script src="<%=basePath%>/assets/js/jquery-2.1.1.min.js"></script>
<script src="<%=basePath%>/assets/js/fontSize.js"></script>
<!-- <link href="<%=basePath%>/assets/imgTools/style.css" rel="stylesheet"
	type="text/css"> -->
<link href="<%=basePath%>/assets/layer/mobile/need/layer.css"
	rel="stylesheet" type="text/css">
	<link rel="stylesheet"
	href="<%=basePath%>assets/font-awesome-4.7.0/css/font-awesome.min.css">
<script src="<%=basePath%>/assets/layer/mobile/layer.js"></script>
<style>
body {
	padding-bottom: 1.2rem
}

.gerenziliao, .content1, .content2 {
	background: #fff;
	margin-bottom: 0.1rem
}

.gerenziliao_top {
	width: 100%;
	height: 2.5rem;
	background: url("<%=basePath%>/assets/imgCenter/bj2.jpg") no-repeat left
		top;
	background-size: 100% 100%;
	position: relative
}

.fanhui {
	font-size: 0.4rem;
	width: 0.8rem;
	height: 1rem;
	line-height: 1rem;
	text-align: center;
	color: #fff;
}

.header_erweima {
	width: 0.4rem;
	height: 0.4rem;
	display: block;
	margin: 0.3rem 0.5rem 0.3rem 0
}

.header_erweima img {
	width: 100%;
	height: 100%
}

.header_fenxiang {
	width: 0.4rem;
	height: 0.4rem;
	display: block;
	margin: 0.3rem
}

.header_fenxiang img {
	width: 100%;
	height: 100%
}

.grzl_t_b {
	position: absolute;
	width: 100%;
	height: 1rem;
	left: 0;
	bottom: 0
}

.zhaoxiangji {
	width: 0.5rem;
	height: 0.45rem;
	display: block;
	position: absolute;
	left: 0.3rem;
	bottom: 0.1rem
}

.zhaoxiangji img {
	width: 100%;
	height: 100%
}

.grzl_t_b_touxiang {
	position: absolute;
	right: 0.5rem;
	bottom: -30%;
	width: 1rem;
	height: 1rem;
	border-radius: 50%;
	overflow: hidden
}

.grzl_t_b_touxiang img {
	width: 100%;
	height: 100%
}

.mingzi {
	font-size: 0.3rem;
	line-height: 0.8rem;
	width: 90%;
	padding: 0 5%;
	font-weight: bold
}

.shuju>span {
	float: left;
	width: 15%;
	text-align: center;
	font-size: 0.20rem;
	padding-bottom: 0.1rem;
}

.shuju>span i {
	width: 100%;
	height: 0.3rem;
	display: block;
	text-align: center;
	font-weight: bold;
	font-size: 0.26rem
}

.bianjiziliao {
	border: 1px solid #999;
	color: #666;
	border-radius: 0.05rem;
	font-size: 0.24rem;
	width: 1.4rem;
	text-align: center;
	height: 0.4rem;
	line-height: 0.4rem;
	font-weight: bold;
	margin-right: 0.5rem
}

.denglushijian {
	width: 90%;
	padding: 0 5%;
	height: 0.4rem;
	line-height: 0.6rem;
	font-size: 0.16rem;
	color: #ccc
}

.gexingqianming {
	width: 90%;
	padding: 0 5%;
	line-height: 0.6rem;
	font-size: 0.2rem
}

.content1 ul li {
	margin: 0 0.2rem;
	height: 0.8rem;
	line-height: 0.8rem;
	border-bottom: 1px solid #f1f1f1;
	padding: 0 0.2rem;
}

.content1 ul li img {
	float: left;
	width: 0.36rem;
	height: 0.36rem;
	margin: 0.22rem
}

.content1 ul li span {
	font-size: 0.24rem;
	height: 0.8rem;
	line-height: 0.8rem;
}

.shanxuan ul {
	height: 0.65rem;
	border-bottom: 1px solid #f1f1f1
}

.shanxuan ul li {
	float: left;
	padding: 0 0.3rem
}

.shanxuan ul li a {
	display: block;
	border-bottom: 0.1rem solid #fff;
	text-align: center;
	font-size: 0.28rem;
	height: 0.6rem;
	line-height: 0.6rem
}

.shanxuan ul li a.active {
	border-bottom: 0.1rem solid orange
}

.dingdan>ul>li {
	border-bottom: 1px solid #ccc
}

.dingdanriqi {
	width: 20%
}

.riqi_day {
	width: 100%;
	height: 1rem;
	font-size: 0.4rem;
	font-weight: bold;
	text-align: center;
	display: block;
	line-height: 1rem
}

.riqi_month {
	width: 100%;
	height: 1rem;
	font-size: 0.24rem;
	text-align: center;
	display: block
}

.dingdanneirong_title {
	font-size: 0.26rem;
	height: 0.6rem;
	line-height: 0.6rem
}

.dingdanneirong {
	width: 80%
}

.dingdanneirong>li {
	border-bottom: 1px solid #ccc;
	padding-bottom: 0.1rem
}

.dingdanneirong>li:last-child {
	border-bottom: none
}

.dingdanxiangqing>img {
	width: 20%;
	float: left;
	height: 1rem
}

.dingdanxiangqing_text {
	width: 75%;
	padding-left: 2%
}

.ddxq_text {
	font-size: 0.2rem;
	line-height: 0.4rem
}

.dingdanxiangqing_text>span {
	color: red;
	font-size: 0.16rem;
}
.about_us a .img{
	display: none;
}
.about_us a .img2{
	display: block;
}
.about_us a p{
	color: #e0620d;
}
.fa-angle-right{
	float:right;
	line-height:0.8rem;
	font-size: 0.32rem;
	color: #999;
}
.info{
	float: right;
	border-top: none;
	margin-top: 0.2rem;
    margin-right: 0.24rem;
    font-size: 0.28rem;
    color: #fff;
}
</style>
</head>
<body>
	<div class="gerenziliao">
		<div class="gerenziliao_top">
			<div class="grzl_t_t clearFirx">
				<a class="info" onclick="toSystemInfo()"><i class="fa fa-commenting-o"></i></a>
			</div>
			<div class="grzl_t_b">
				<c:if test="${not empty users.userPhoto}">
					<a href="javascript:;" class="grzl_t_b_touxiang"> <img
						src="<%=basePath%>app/getGoodsPhotoByName?goodsImage=${users.userPhoto}"
						id="handImdShow1">
					</a>
				</c:if>
				<c:if test="${empty users.userPhoto}">
					<a href="javascript:;" class="grzl_t_b_touxiang"> <img
						src="<%=basePath%>/assets/css/aboutUs/logo.png" id="handImdShow2">
					</a>
				</c:if>
			</div>
		</div>
		<div class="gerenziliao_bot">
			<c:choose>
				<c:when test="${users.userName != null}">
					<h3 class="mingzi">${users.userName}</h3>
				</c:when>
				<c:otherwise>
					<h3 class="mingzi">&emsp;</h3>
				</c:otherwise>
			</c:choose>
			<div class="shuju clearFirx">
				<c:choose>
					<c:when test="${not empty orderCount}">
						<span class="zai"><i>${orderCount}</i>订单数</span>
					</c:when>
					<c:otherwise>
						<span class="zai"><i>0</i>订单数</span>
					</c:otherwise>
				</c:choose>
				<c:choose>
					<c:when test="${not empty focusCount}">
						<span><i>${focusCount}</i>关注数</span>
					</c:when>
					<c:otherwise>
						<span class="zai"><i>0</i>关注数</span>
					</c:otherwise>
				</c:choose>
				<c:choose>
					<c:when test="${not empty fansCount}">
						<span><i>${fansCount}</i>粉丝数</span>
					</c:when>
					<c:otherwise>
						<span class="zai"><i>0</i>粉丝数</span>
					</c:otherwise>
				</c:choose>


				<a href="javascript:;" class="float_r bianjiziliao"
					onclick="toEditData()">编辑资料</a>
			</div>
		</div>
	</div>
	<div class="content1">
		<ul>
			<li onclick="toAllOrders()" class="clearFirx"><span
				class="float_l">我的订单</span>
				<i class="fa fa-angle-right"></i>
			</li>
			<li onclick="toTwoHandPublish()" class="clearFirx"><span
				class="float_l">我的发布</span>
				<i class="fa fa-angle-right"></i>	
			</li>
			<li onclick="toMyCollection()" class="clearFirx"><span
				class="float_l">我的收藏</span>
				<i class="fa fa-angle-right"></i>	
			</li>
			<li onclick="toMyFocus()" class="clearFirx"><span
				class="float_l">我的关注</span>
				<i class="fa fa-angle-right"></i>
			</li>
			<c:if test="${merchant.state == 1}">
				<li onclick="audit()" class="clearFirx"><span
					class="float_l">申请开店（审核中）</span>
					<i class="fa fa-angle-right"></i>
				</li>
			</c:if>
			<c:if test="${merchant.state == 2}">
				<li onclick="javascript:window.location.href='<%=basePath%>app/goodsList?merchantId=${merchant.merchantId}'" class="clearFirx"><span
					class="float_l">我的店铺</span>
					<i class="fa fa-angle-right"></i>
				</li>
			</c:if>
			<c:if test="${empty merchant.state || merchant.state == 3}">
				<li onclick="toApplyShop()" class="clearFirx"><span
					class="float_l">申请开店</span>
					<i class="fa fa-angle-right"></i>
				</li>
			</c:if>
			<li onclick="address()" class="clearFirx"><span class="float_l">收货地址</span>
				<i class="fa fa-angle-right"></i>
			</li>
			<li onclick="toPublishRule()" class="clearFirx"><span
				class="float_l">发布规则</span>
				<i class="fa fa-angle-right"></i>
			</li>
<!-- 			<li onclick="toComplaintAndAdvice()" class="clearFirx"><span -->
<!-- 				class="float_l">投诉建议</span> -->
<!-- 				<i class="fa fa-angle-right"></i> -->
<!-- 			</li> -->
			<li onclick="toAboutUs()" class="clearFirx"><span
				class="float_l" onclick="toAboutUs()">关于我们</span>
				<i class="fa fa-angle-right"></i>
			</li>
		</ul>
	</div>
		<%@ include file="footer.jsp"%>
	</script>
</body>
<script>
//跳转购物车
function toShoppingCard(){
	window.location.href="<%=basePath%>app/getShoppingCardList";
};
//跳转发布规则
function toPublishRule(){
	window.location.href="<%=basePath%>jsp/app/pushRule.jsp";
};
//跳转二手发布
function toTwoHandPublish(){
	window.location.href="<%=basePath%>app/toTwoHandPushList";
};
//跳转我的订单
function toAllOrders(){ 
	window.location.href="<%=basePath%>app/getUserOrderList";
};
//跳转我的收藏
function toMyCollection(){
	window.location.href="<%=basePath%>app/getFavoritesList";
};
//跳转我的关注
function toMyFocus(){
	window.location.href="<%=basePath%>app/getAttentionList";
};
//跳转申请开店
function toApplyShop(){
	window.location.href="<%=basePath%>jsp/app/applyShop.jsp";
};
//跳转系统消息
function toSystemInfo(){
	window.location.href="<%=basePath%>app/getSystemMessage";
};
//收货地址管理
function address(){
	window.location.href="<%=basePath%>app/getAddressList";
};
//跳转投诉建议
function toComplaintAndAdvice(){
	window.location.href="<%=basePath%>jsp/app/advice.jsp";
};
//跳转关于我们
function toAboutUs(){
	window.location.href="<%=basePath%>jsp/app/aboutUs.jsp";
};
//跳转编辑资料
function toEditData(){
	window.location.href="<%=basePath%>app/toMyProfile";
};
function audit(){
	layer.open({
	    content: '审核中，请等待',
	    skin: 'msg',
	    time: 2 //2秒后自动关闭
	});
}
</script>
</html>